package com.spring.campus_express_delivery.service;

import com.spring.campus_express_delivery.entity.PageBean;
import com.spring.campus_express_delivery.entity.Users;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.List;
import java.util.Map;


public interface UsersService {
    //通过openid来查询此用户是否存在
    Users selectUserByOpenid(String appid);
    //微信小程序注册用户
    void insertWXUser(Users user);
    //Users selectUsersByidentityID_password(String identity_id, String password);
    //根据用户identity_id查询用户信息，web注册用户，登录,根据identity_id查询用户用到
    Users selectUserByIdentityId(String identity_id);
    //web端注册用户
    void insertWebUser(Users user);
    //根据id修改用户信息时需要先查询id
    Users selectUsersById(Integer id);
    //根据id修改用户信息
    void updateUsersInfoById(Users users);
    //修改用户自己的信息
    void updateInfoByMyself(Users users);
    //用户列表
    PageBean<Users> selectUsersByPage(int size, int page, String sort, String asc);

    //根据d删除用户
    void deleteUserById(Integer id);
    //统计数目
    Map<String, Integer> count();
    //统计数目
    int selectCountByUser();
    //导入用户信息
    void importUsersExcel(MultipartFile usersFile) throws IOException;
    //导出用户信息
    void exportUsersExcel(HttpServletResponse response) throws Exception;
    List<Users> selectAllUsers();
    Users selectId(int id);



}
